package com.cangshukj.junong.service.impl;

import java.util.List;
import com.cangshukj.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.cangshukj.junong.mapper.AgencyReginfoMapper;
import com.cangshukj.junong.domain.AgencyReginfo;
import com.cangshukj.junong.service.IAgencyReginfoService;

/**
 * 代理服务登记信息Service业务层处理
 * 
 * @author wangjie
 * @date 2025-04-01
 */
@Service
public class AgencyReginfoServiceImpl implements IAgencyReginfoService 
{
    @Autowired
    private AgencyReginfoMapper agencyReginfoMapper;

    /**
     * 查询代理服务登记信息
     * 
     * @param id 代理服务登记信息主键
     * @return 代理服务登记信息
     */
    @Override
    public AgencyReginfo selectAgencyReginfoById(String id)
    {
        return agencyReginfoMapper.selectAgencyReginfoById(id);
    }

    /**
     * 查询代理服务登记信息列表
     * 
     * @param agencyReginfo 代理服务登记信息
     * @return 代理服务登记信息
     */
    @Override
    public List<AgencyReginfo> selectAgencyReginfoList(AgencyReginfo agencyReginfo)
    {
        return agencyReginfoMapper.selectAgencyReginfoList(agencyReginfo);
    }

    /**
     * 新增代理服务登记信息
     * 
     * @param agencyReginfo 代理服务登记信息
     * @return 结果
     */
    @Override
    public int insertAgencyReginfo(AgencyReginfo agencyReginfo)
    {
        agencyReginfo.setCreateTime(DateUtils.getNowDate());
        return agencyReginfoMapper.insertAgencyReginfo(agencyReginfo);
    }

    /**
     * 修改代理服务登记信息
     * 
     * @param agencyReginfo 代理服务登记信息
     * @return 结果
     */
    @Override
    public int updateAgencyReginfo(AgencyReginfo agencyReginfo)
    {
        agencyReginfo.setUpdateTime(DateUtils.getNowDate());
        return agencyReginfoMapper.updateAgencyReginfo(agencyReginfo);
    }

    /**
     * 批量删除代理服务登记信息
     * 
     * @param ids 需要删除的代理服务登记信息主键
     * @return 结果
     */
    @Override
    public int deleteAgencyReginfoByIds(String[] ids)
    {
        return agencyReginfoMapper.deleteAgencyReginfoByIds(ids);
    }

    /**
     * 删除代理服务登记信息信息
     * 
     * @param id 代理服务登记信息主键
     * @return 结果
     */
    @Override
    public int deleteAgencyReginfoById(String id)
    {
        return agencyReginfoMapper.deleteAgencyReginfoById(id);
    }
}
